//
//  OosOfferEntry.m
//  oos4ios
//
//  Created by Pablo Gonzalez on 9/20/11.
//  Copyright 2011 11870.com. All rights reserved.
//

#import "OosOfferEntry.h"

@implementation OosServiceSlug

+ (NSString *)extensionElementLocalName     { return @"serviceSlug"; };

@end

@implementation OosValidFrom

+ (NSString *)extensionElementLocalName     { return @"validFrom"; }

@end

@implementation OosValidTo

+ (NSString *)extensionElementLocalName     { return @"validTo"; }

@end

@implementation OosDescription

+ (NSString *)extensionElementLocalName     { return @"description"; }

@end

@implementation OosConditions

+ (NSString *)extensionElementLocalName     { return @"conditions"; }

@end
@implementation OosSubscribed

+ (NSString *)extensionElementLocalName     { return @"subscribed"; }

@end

@implementation OosOfferEntry

- (void)addExtensionDeclarations
{
    [super addExtensionDeclarations];
    
    [self addExtensionDeclarationForParentClass:[self class] 
                                   childClasses: [OosServiceSlug class], 
     [OosValidFrom class], [OosValidTo class], [OosOfferType class], 
     [OosDescription class], [OosConditions class], [OosSignups class], 
     [OosValue class], [OosSubscribed class] ];
}

+ (NSString *)defaultServiceVersion 
{
	return @"2.0";
}

#pragma mark <oos:serviceSlug>

- (OosServiceSlug *)serviceSlug
{
    return [self objectForExtensionClass:[OosServiceSlug class]];
}

#pragma mark <oos:validFrom>

- (OosValidFrom *)validFrom
{
    return [self objectForExtensionClass:[OosValidFrom class]];
}

#pragma mark <oos:validTo>

- (OosValidTo *)validTo
{
    return [self objectForExtensionClass:[OosValidTo class]];
}

#pragma mark <oos:offerType>

- (OosOfferType *)offerType
{
    return [self objectForExtensionClass:[OosOfferType class]];
}

#pragma mark <oos:description>

- (OosDescription *)description
{
    return [self objectForExtensionClass:[OosDescription class]];
}

#pragma mark <oos:conditions>

- (OosConditions *)conditions
{
    return [self objectForExtensionClass:[OosConditions class]];
}

#pragma mark <oos:signups>

- (OosSignups *)signups
{
    return [self objectForExtensionClass:[OosSignups class]];
}

#pragma mark <oos:value>

- (OosValue *)value
{
    return [self objectForExtensionClass:[OosValue class]];
}

#pragma mark <oos:subscribed>

- (OosSubscribed *)subscribed
{
    return [self objectForExtensionClass:[OosSubscribed class]];
}

@end
